/*
 * State.h
 *
 *  Created on: 27/07/2010
 *      Author: alex
 */

#ifndef STATE_H_
#define STATE_H_

#include <SDL/SDL.h>


enum StateType {
	STATE_SPLASH,
	STATE_ARENA,
	STATE_END
};


class State {

public:

	State() : finished(false) { }

	virtual State& update(unsigned dt) = 0;

	virtual void render(SDL_Surface* screen) = 0;

	bool hasFinished() const {
		return finished;
	}

	StateType getNext() const {
		return next;
	}

protected:

	bool finished;

	StateType next;

};


#endif /* STATE_H_ */
